<script setup>
import {useRouter} from "vue-router";

const router = useRouter();
const goHome = () => {
  router.push("/");
};

</script>

<template>
  <article class="jia-flex-center">
    <div class="jia-main">
      <div class="jia-main-img jia-item">
        <img src="@/assets/not-found/404.svg" alt="NotFound">
      </div>
      <div class="jia-text jia-item">
        <div class="code">404</div>
        <div class="msg">你查看的页面貌似丢失了呢...</div>
        <div class="action">
          <a-tag color="blue" @click="goHome">返回首页!</a-tag>
        </div>
      </div>
    </div>
    <div class="jia-ICP">CJia ©2023 | 蜀ICP备2023008183号-2</div>
  </article>
</template>

<style scoped lang="less">
article {
  position: relative;
  width: 100%;
  min-height: 100vh;
  background-color: rgba(223, 223, 255, 0.39);

  .jia-main {
    width: 80%;
    max-width: 1000px;
    max-height: 500px;
    min-width: 600px;
    background-color: white;
    font-size: 0;
    border-radius: 20px;
    box-shadow: 0 0 50px 0 rgba(146, 146, 146, 0.63);

    .jia-main-img {
      background-color: rgba(253, 216, 168, 0.692);
      border-top-left-radius: 20px;
      border-bottom-left-radius: 20px;
    }

    .jia-text {

      .code {
        font-size: clamp(150px, 20vw, 150px);
        color: rgb(86, 86, 253);
        font-weight: bolder;
        text-align: center;
      }

      .msg {
        font-size: 18px;
        text-align: center;
        font-weight: 200;
        margin-bottom: 20px;
      }

      .action {
        font-size: 15px;
        font-weight: 200;
        text-align: center;
        text-decoration-line: underline;
        cursor: pointer;
      }
    }

    .jia-item {
      display: inline-block;
      vertical-align: middle;
      width: 50%;
    }
  }

  .jia-ICP {
    position: absolute;
    top: 880px;
    left: 850px;
    color: #777;
  }

}
</style>